<?
$footer = $MAIN->site->template_path."/footer.php";
if(file_exists($header)){
    require_once $footer;
}else{
    Logger::error("footer not found");
}